home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1996 February: Tool Chest / Apple Developer CD Series Tool Chest February 1996 (Apple Computer)(1996).iso / Sample Code / AOCE Sample Code / PowerTalk Access Modules / Sample SMSAM / SampleSMSAM Source / HFSHalfGateway / HFSLetter.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-07-28  |  3.3 KB  |  101 lines  |  [TEXT/MPS ]

  1. /*
  2.     File:        HFSLetter.h
  3.  
  4.     Copyright:    © 1991-1994 by Apple Computer, Inc.
  5.                 All rights reserved.
  6.  
  7.     Part of the AOCE Sample SMSAM Package.  Consult the license
  8.     which came with this software for your specific legal rights.
  9.  
  10. */
  11.  
  12.  
  13.  
  14. #ifndef __HFSLETTER__
  15. #define __HFSLETTER__
  16.  
  17. #ifndef __LETTER__
  18. #include "Letter.h"
  19. #endif
  20.  
  21. class TVirtualFolder;
  22. class TVirtualFile;
  23. class TRecipient;
  24. class THFSRecipient;
  25.  
  26. /***********************************|****************************************/
  27.  
  28. class THFSLetter : public TLetter 
  29. {
  30. public:
  31.     THFSLetter(TVirtualFile* theContent, TVirtualFolder* theEnclosure,RString& theSubject, RString& sendTo);
  32.     virtual ~THFSLetter();
  33.  
  34. public:
  35.     virtual Boolean GetLetterID (BLJLetterID& letterID) const;
  36.     virtual Boolean GetReplyID (BLJLetterID& replyID) const;
  37.     virtual Boolean GetConversationID (BLJLetterID& conversationID) const;
  38.  
  39.     virtual Boolean GetSendTimeStamp (BLJTime& sendTime) const;
  40.  
  41.     virtual Boolean GetLetterPriority (TLetter::LetterPriority& priority) const;
  42.  
  43.     virtual Boolean GetSubject (TRString& subject) const;
  44.  
  45.     //    What type of letter is this?
  46.     virtual Boolean IsLetterAutoForwarded (Boolean& yesItIs) const;
  47.     virtual Boolean IsLetterAutoReply (Boolean& yesItIs) const;
  48.     virtual Boolean CanLetterBeAutoForwarded (Boolean& yesItCan) const;
  49.  
  50.     virtual unsigned short GetRecipientCount(RecipientTypeSet recipientType) const;
  51.     virtual TRecipient* GetRecipient (RecipientTypeSet recipientType, unsigned short index) const;
  52.  
  53.     //
  54.     //    RECIPIENT REPORTS METHODS
  55.     //    =========================
  56.     //
  57.     virtual Boolean GetRecipientStatus(RecipientTypeSet recipientType, unsigned short index, RecipientStatusSet& status) const;
  58.     virtual Boolean SetRecipientStatus(RecipientTypeSet recipientType, unsigned short index, RecipientStatusSet status);
  59.     virtual unsigned short GetUnknownRecipientCount() const;
  60.  
  61.     //    These routines return booleans related to the reports requested    about this letter.
  62.     virtual Boolean DeliveryReceiptRequested(Boolean &yesItIs) const;
  63.     virtual Boolean NonDeliveryReportRequested (Boolean& yesItIs) const;
  64.     virtual Boolean EncloseOriginalLetterInReport (Boolean &yesItIs) const;
  65.  
  66.     //
  67.     //    LETTER CONTENT METHODS
  68.     //    ======================
  69.     //        
  70.     virtual unsigned long             GetContentTypeCount ( ) const;
  71.     virtual OSType                     GetContentType ( unsigned long i ) const;
  72.  
  73.     virtual unsigned long             GetSegmentCount( OSType contentType ) const;
  74.     virtual Boolean                 GetSegmentData( OSType contentType, unsigned long index, unsigned long offset,void *data, long& maximumDataSize ) const;
  75.     virtual Boolean                 GetSegmentInfo( OSType contentType, unsigned long index, BLJLetterBlockType& blockType, long& blockLength ) const;
  76.     
  77.     //    This call returns information about the enclosures in the letter
  78.     virtual TVirtualFolder* GetEnclosuresFolder() const;
  79.  
  80.     //    This call returns another letter which is 'nested' inside of the current letter.
  81.     virtual unsigned short GetNestedLetterCount() const;
  82.     virtual TLetter* GetNestedLetter(unsigned short index) const;
  83.  
  84.     //    Debugging methods
  85.     virtual ostream& DescribeSubclass(ostream& s) const;
  86.     virtual ostream& operator >> (ostream& s) const;
  87.     
  88. private:
  89.     TVirtualFile*         fVFile;
  90.     RString                fSubject;
  91.     THFSRecipient*        fSendTo;
  92.     THFSRecipient*        fSentFrom;
  93.     TVirtualFolder*        fEnclosure;
  94.     BLJLetterID         fLetterID;
  95.     unsigned long        fSendTime;
  96. };
  97.  
  98. /***********************************|****************************************/
  99.  
  100. #endif    // __HFSLETTER__
  101.